#ifndef __GLF_COMPILER_MSVC_H_INCLUDED__
#define __GLF_COMPILER_MSVC_H_INCLUDED__

typedef   signed __int64 int64;
typedef unsigned __int64 uint64;

//#include <cstdarg>

namespace glf {
	void* alloca(size_t size);
	typedef int errno_t;
} //namespace glf

#define STD_NAMESPACE

#define GLF_ATTRIBUTE_ALIGN(num)	__declspec(align(num))
#define GLF_ALIGNOF(type)			__alignof(type)
#define GLF_STRUCT_PACK(num) 
#define GLF_BREAKPOINT()			{ __debugbreak(); }

#define GLF_COMPILER_OFFSETOF(s,m)		offsetof(s,m)

#define GLF_REMINDER(msg)			message("REMINDER: " msg)

#ifdef OS_WP8
	#define GLF_HAS_BUILTIN_COMPILER_TLS 0
#else
	#define GLF_HAS_BUILTIN_COMPILER_TLS 1
	#define GLF_BUILTIN_TLS_DECL __declspec(thread)
#endif

#include <stdarg.h>

typedef va_list				glfVaList;

#define glfVaStart(l, arg)	_crt_va_start(l, arg)
#define glfVaEnd			_crt_va_end
#define glfVaArg			_crt_va_arg

#pragma warning(disable:4100)
#pragma warning(disable:4505) //unreferenced local function has been removed
#pragma warning(disable:4201) //nonstandard extension used : nameless struct/union
#pragma warning(disable:4355) //'this' : used in base member initializer list

#endif
